<button nz-button [nzType]="'primary'" (click)="newRow()" acl [acl-ability]="102">
    <i nz-icon nzType="plus"></i>
    <span>{{ 'button.new' | i18n }}</span>
  </button>

  <button nz-button [nzType]="'primary'" nzDanger="true" (click)="saveRow()" acl [acl-ability]="102">
    <i nz-icon nzType="save"></i>
    <span>{{ 'button.save' | i18n }}</span>
  </button>
  <st #st [data]="produceData" [columns]="columns">
    <ng-template st-row="ColumnTitleTpl" let-item let-index="index">
      <input *ngIf="item.edit" nz-input [ngModel]="item.keyName"
        (ngModelChange)="st.setRow(index, { keyName: $event })" />
      <ng-container *ngIf="!item.edit">{{ item.keyName }}</ng-container>
    </ng-template>
   
    <ng-template st-row="ColumnTypeTpl" let-item let-index="index">
      <nz-select *ngIf="item.edit" [ngModel]="item.dataSide"
        (ngModelChange)="st.setRow(index, { dataSide: $event })">
        <nz-option nzValue="AnySide" nzLabel="AnySide"></nz-option>
        <nz-option nzValue="ServerSide" nzLabel="ServerSide"></nz-option>
        <nz-option nzValue="ClientSide" nzLabel="ClientSide"></nz-option>
      
      </nz-select>

      <ng-container *ngIf="!item.edit">{{ item.dataSide }}</ng-container>
    </ng-template>

    <ng-template st-row="ColumnDataTypeTpl" let-item let-index="index">
      <nz-select *ngIf="item.edit" [ngModel]="item.type"
        (ngModelChange)="st.setRow(index, { type: $event })">
        <nz-option nzValue="Boolean" nzLabel="Boolean"></nz-option>
        <nz-option nzValue="String" nzLabel="String"></nz-option>
        <nz-option nzValue="Long" nzLabel="Long"></nz-option>
        <nz-option nzValue="Double" nzLabel="Double"></nz-option>
        <nz-option nzValue="Json" nzLabel="Json"></nz-option>
        <nz-option nzValue="XML" nzLabel="XML"></nz-option>
        <nz-option nzValue="Binary" nzLabel="Binary"></nz-option>
        <nz-option nzValue="DateTime" nzLabel="DateTime"></nz-option>
      </nz-select>

      <ng-container *ngIf="!item.edit">{{ item.type}}</ng-container>
    </ng-template>


  </st>